Myriad Macro v4.0 Command Reference Guide

When triggering a Command, a Status Panel is displayed over the top of the Cart Players, and the Log Information Panel.  If you prefer not to have this Status Panel displayed, then you can prefix the Command name with an exclamation mark ("!"). You can also click on the panel over the Cart Players to hide it for the duration of that Command.

Normally Commands triggered by either Log Events or by being attached to carts are fired "Asynchronously" meaning that they will fire very soon after they are triggered, but not immediately. Usually this gap is very small and will not be noticed, but where it is critical you can prefix the Command name with "@" (or "!@" for a silent version) to make the command run immediately - i.e. Synchronously. However, it is very important that you avoid using Commands that will take a long time to complete, or that use the WAIT function as these may cause Myriad to become non-responsive until the Command has finished executing.

Myriad Startup
When Myriad starts up it looks for a a command called 'STARTUP' and runs it automatically. If your command is called 'STARTUPPROMPT' then the user is asked if they want to 'Run the Startup Macro?'

Overriding 'shared' commands with profile specific versions
You can also override a 'shared' command (i.e. those stored in the Data location\Commands) with a profile specific command by creating a local file in C:\Documents and Settings\All Users\Application Data\P Squared\Myriad v3\Profiles\<ProfileName>\Commands folder. For example you may have a command called ImportNews that carries out a certain action on all machines, but on one specific machine you want to alter the way this command works so you copy the ImportNews.cm3 file into the local location and alter it using notepad.

Overriding all commands with local computer specific versions
Shared and profile specific commands can also be overridden by a command with the same name stored in C:\Documents and Settings\All Users\Application Data\P Squared\Myriad v3\Commands. This command is therefore available to Myriad regardless of which Profile it is loaded with.

TCP/IP Access to the Command Processor

As wel as using stored commands, you can also communicate directly with the Command Processor via a TCP Connection to a computer running Myriad. You will need to turn on the Myriad Settings option to Allow TCP/IP Connections.

There is an additional command that can be used when using the TCP interface:

	Field		| Usage
	====================================================================================================================
	GET VALUE	| You can use this to return information from the Command processor - the string you send is processed
			| by the PEP and then returned back to you. The contents of the string are not processed in any way
			| so you can use any other text in the query string.
			|
			| Example: 	GET VALUE IWANTTOKNOW=<PEP_COMPUTERNAME>
			|		(For example, this might return in SET VALUE IWANTTOKNOW=STUDIO1XP)
			|
			| Example: 	GET VALUE WHATSON...<PEP_CURRENTLOGITEM_ITEMTITLE>
			|		(For example, this might return in SET VALUE WHATSON...Station Ident)

Pre-Execution Processor (PEP)

Before any Command is executed, the PEP reviews the command string to insert any Dynamic data (i.e. Current Date etc.)

Dynamic Data Fields must be prefixed <PEP_ and end with a closing >  - for example, the LOGMODE field must be entered as <PEP_LOGMODE>

The Supported fields are:

	Field		| Usage
	====================================================================================================================
	COMPUTERNAME| The Field is replaced with the Windows Computer Network Name of the computer
			| 
			| Example: 	<PEP_COMPUTERNAME>
			|		(For example, this might result in STUDIO1XP)
	====================================================================================================================
	CURRENTUSER	| The Field is replaced with the Login Name of the Logged in User 
			| 
			| If no user is logged in then the result will be an empty string
			|
			| Example: 	<PEP_CURRENTUSER>
			|		(For example, this might result in JOHNJONES if John Jones is logged in)
			|
			| Notes:	You can access other properties of the Current User by using
			|		  <PEP_CURRENTUSER_{Field}> - e.g. <PEP_CURRENTUSER_PHONENUMBER1> 
			|		The following fields are currently supported:
			|			Reference,GUID,Category,SecurityGroup,UseSecurityGroupDefaults,SoftwareAccount
			|			Created,CreatedString,LastModified,LastModifiedString,AccessEnd,AccessEndString
			|			Name,Company,JobTitle,Notes,ExternalReference,PhoneNumber1,PhoneNumber2,FaxNumber
			|			MobileNumber,Email1,Email2,Email3,Website1,Website2,Address,LoginName
			|			LoginDisabled,LoginCanChangePassword,LoginMustChangePassword,LoginAllowAutoLogin
			|			LastLoginString,LastLoginSoftware,PersonalToContact,SystemAccount,EditHistory
			|			HasPermissions,HasPreferences,vCard,FilesLocation
	====================================================================================================================
	DATABASE	| The Field is replaced with the Database Name of the open Station Database
			| 
			| If no database is open then the result will be an empty string
			|
			| Example: 	<PEP_DATABASE>
			|		(For example, this might result in MYSTATIONDATABASE if that is your database name)
			|
			| Notes:	You can access other properties of the Database by using
			|		  <PEP_DATABASE_{Field}> - e.g. <PEP_DATABASE_DESCRIPTION> 
			|
			|		The following fields are currently supported 
			|			DBConnect,DBFilename,DBLocation,DBName,DBVersion,Description
			|			IsSqlServer,LastAccessed,LastAccessedSoftware,LastBackup
			|			PSQDBType,PSQVersion,PSQVersionSec,Serialisation
			|
			| Notes: 	Some fields will not return a value depending on if you are using SQL or an Access databases
	====================================================================================================================
	CURRENTLOGITEM 
	NEXTLOGITEM 
	NEXTCUEABLELOGITEM 
			| The partial field is replaced by details from the 'Current', 'Next' or 'Next Cueable' Log item. 
			| It must be followed by the information that you want to retrieve - e.g. ItemTitle. 
			| 
			| If no Log is open, or the Log is not running then the result will be an empty string
			|
			| Example: 	<PEP_CURRENTLOGITEM_ITEMTITLE> by <PEP_CURRENTLOGITEM_ARTISTNAME_1>
			|		The following fields are currently supported:
			|			Reference,ReferenceString,HDReference
			|			ItemDate,ReferenceTime
			|			ItemTitle,ArtistName_1,ArtistName_2,ArtistName_3
			|			ItemDescription_1,ItemDescription_2,ItemDescription_3
			|			ItemType,ItemFlags,OriginalItemFlags,ItemStatus
			|			ActualEndType,ScheduledEndType
			|			AutoFadeStart,AutoFadeLength,HasAutoFade
			|			FadeInStart,FadeOmLength,HasFadeIn
			|			EarlyFadeStart,EarlyFadeLength,HasEarlyFade
			|			ScheduledLength,EstimatedLength,PreCueOverride,ExtroOverride
			|			ItemReference,SchedulerReference
			|			VoiceReference,VoiceStartOffset,VoiceHDReference
			|			StudioNotes,WebNotes,DABNotes
			|			Information_1,Information_2,Information_3,Information_4
			|			InformationString_1,InformationString_2,InformationString_3,InformationString_4
			|			HardwareEndNumber_1,HardwareEndNumber_2,HardwareEndState_1,HardwareEndState_2
			|			ItemTypeDescription_0,ItemTypeDescription_1,ItemTypeDescription_2,ItemTypeDescription_3
			|			ItemEndType,ActualEndTypem,ScheduledEndType
			|			ItemEndTypeDescription_0,ItemEndTypeDescription_1
			|			ItemEndTypeDescription_2,ItemEndTypeDescription_3
			|			ActualEndTypeDescription_0,ActualEndTypeDescription_1
			|			ActualEndTypeDescription_2,ActualEndTypeDescription_3
			|			ScheduledEndTypeDescription_0,ScheduledEndTypeDescription_1
			|			ScheduledEndTypeDescription_2,ScheduledEndTypeDescription_3
			|			EstimatedStartDateTimeXML,EstimatedStartDateTimeGMTXML
			|			EstimatedEndDateTimeXML,EstimatedEndDateTimeGMTXML
			|			Serialisation,XML
	====================================================================================================================
	CURRENTLOGITEMOFFSET 
			| The partial field is replaced by details from the specified item before or after the Current Log item. 
			| It must be followed by a number that determines which item before or after the current item in the log
			| and then the name of the information that you want to retrieve.
			| 
			| If no Log is open, or the Log is not running then the result will be an empty string
			|
			| Example: 	<PEP_CURRENTLOGITEMOFFSET_2_ITEMTITLE> by <PEP_CURRENTLOGITEMOFFSET_2_ARTISTNAME_1>
			|		This would show the Title and Artist from the second item below the current item.
			|		For a list of supported fields see CURRENTLOGITEM above
	====================================================================================================================
	CURRENTLOGVIEWITEM 
			| The partial field is replaced by details from the item currently highlit in the Log Display.
			| It must be followed by the information that you want to retrieve - e.g. ItemTitle. 
			| 
			| If no Log is open, or the Log is not running then the result will be an empty string
			|
			| Example: 	<PEP_CURRENTLOGVIEWITEM_ITEMTITLE> by <PEP_CURRENTLOGVIEWITEM_ARTISTNAME_1>
			|		For a list of supported fields see CURRENTLOGITEM above
	====================================================================================================================
	CURRENTLOGVIEWITEMOFFSET 
			| The partial field is replaced by details from the specified item before or after the item highlit in
			| the Log Display. It must be followed by a number that determines which item before or after the current item
			| and then the name of the information that you want to retrieve.
			| 
			| If no Log is open, or the Log is not running then the result will be an empty string
			|
			| Example: 	<PEP_CURRENTLOGVIEWITEMOFFSET_2_ITEMTITLE> by <PEP_CURRENTLOGVIEWITEMOFFSET_2_ARTISTNAME_1>
			|		This would show the Title and Artist from the second item below the current item.
			|		For a list of supported fields see CURRENTLOGITEM above
	====================================================================================================================
	DATE_XXXX	| The Field is replaced with the current date in the format given by XXXX. 
			| The XXXX part can be built out of several different sections to build a custom date format.
			| You can also use several characters as separators such as - , : etc.
			|
			| XXXX Values:
			|		YY 	: Reports a 2 digit year i.e. 07
			|		YYYY 	: Reports a 4 digit year i.e. 2007

			|		M	: Reports a 1 or 2 digit Month i.e. 8 or 10
			|		MM	: Reports a 2 digit Month i.e. 08
			|		MMM	: Reports a short text name of the Month i.e. Aug
			|		MMMM	: Reports a full text name of the Month i.e. August

			|		D	: Reports a 1 or 2 digit Day i.e. 3 or 18
			|		DD	: Reports a 2 digit Day i.e. 03
			|		DDD	: Reports a short text name of the Day i.e. Fri
			|		DDDD	: Reports a full text name of the Day i.e. Friday
			|		DDDDD	: Reports the date using the Windows Short Date Settings - i.e. 03/08/2007

			| Example: 	<PEP_DATE_YYMMDD>
					(This would result in 070803)
			|  		<PEP_DATE_YY-MM-DD>.LOG
					(This would result in 07-08-03.LOG)
	====================================================================================================================
	LOGDATE_XXXX| The Field is replaced with the current date that the Station Database is running 
			| This may be different from the actual clock date if the last hour in a log has 
			| underrun resulting in the next hour starting early.

			| The XXXX parameter is the same as for the DATE_XXXX Field

			| Example: 	<PEP_LOGDATE_YYMMDD>
	====================================================================================================================
	LOGHOUR	| The Field is replaced with the current hour of the Log that the Station Database is running 
			| This may be different from the actual clock date if an hour in a log has 
			| underrun resulting in the next hour starting early.
			|
			| The Result is always 2 digits in the 24 hour clock
			|
			| Example: 	<PEP_LOGHOUR>
			|		(For example, this might result in 20 if the current hour was 8 o'clock at night)
	====================================================================================================================
	LOGMODE	| The Field is replaced with the mode that the Station Database is running in on the Log Screen 
			| 
			| The only possible results are an empty string (i.e. no database log open) or:
			|		AUTOFADE 
			|		AUTO
			|		LIVE
			|		STANDBY
			|
			| Example: 	<PEP_LOGMODE>
	====================================================================================================================
	MYRIADCOMPUTERID		|  This uses the Myriad Computer ID Number (as found in Myriad Settings>Computers Tab)
					| 
					| Example: 	<PEP_MYRIADCOMPUTERID>
					|		(For example, this might result in 3 for the 3rd computer in the list.)
	====================================================================================================================
	MYRIADCOMPUTERNAME	|  This uses the Myriad Computer Network Name (as found in Myriad Settings>Computers Tab)
					| 
					| Example: 	<PEP_MYRIADCOMPUTERNAME>
					|		(For example, this might result in STUDIO 1 Main Computer)
	====================================================================================================================
	TIME_XXXX	| The Field is replaced with the current Time in the format given by XXXX. 
			| The XXXX part can be built out of several different sections to build a custom date format.
			| XXXX Values:
			|		H 	: Reports a 1 or 2 digit hour i.e. 7 or 11
			|		HH 	: Reports a 2 digit hour i.e. 07
			|
			|		M	: Reports a 1 or 2 digit minute i.e. 8 or 45
			|		MM	: Reports a 2 digit minute i.e. 08
			|
			|		S	: Reports a 1 or 2 digit seconds i.e. 3 or 59
			|		SS	: Reports a 2 digit seconds i.e. 09
			|
			| Example: 	<PEP_TIME_HHMM>
			|		(This would result in 0130)
			|
			| 		<PEP_TIME_H:MM>
			|		(This would result in 1:30)

Command Types:

External:
	Used to run an external windows application - i.e. notepad

	You can also set options for Myriad to wait until the command has executed or to set the Application Priority.

	Example:	notepad.exe \\Server\Share\Info\Weather.txt

Macro:
	Use the built-in Myriad scripting language to perform a sequence of actions. 

	Each Command must be entered on it's own line, with any parameters on the same line. You cannot execute multiple commands on a single line.

On some cases, several variations of the command name are acceptable. These are represented as lists in this documentation.

	Conditional Execution Processor (CoEP):

	To allow you to only execute commands when certain conditions are met, the CoEP reviews each line before execution.
	To use the CoEP, simply start the line with a valid IF statement then add the command at the end of the IF test.

		Syntax:	IF (Test=Result) <Command To Execute>|EXIT

	The equals sign can be replaced with one of the following:
		=	Test must be equal to the Result to execute the command
		<>	Test must be different (i.e. not equal) to the result
		<	Test must be less than the result
		<=	Test must be less than or equals to the result
		>	Test must be less than the result
		>=	Test must be less than or equals to the result

	There is a special Execute command of EXIT which can be used to stop running any further commands from that Macro immediately. For example IF (LOGGEDIN=No) EXIT

	The following Conditional IF tests are available via the CoEP

	TEST		| Usage
	====================================================================================================================
	YEAR		| Tests the Current Year 	
			| Example: 	IF (YEAR=2007) <Command>
	====================================================================================================================
	MONTH		| Tests the Current Month number 	
			| Example: 	IF (MONTH<2) <Command>
	====================================================================================================================
	DAY		| Tests the Current Day of the month
			| Example: 	IF (DAY>=23) <Command>
	====================================================================================================================
	WEEKDAY	| Tests the Current day of the week number (Monday=Day 1, Sunday = Day 7) 	
			| Example: 	IF (WEEKDAY<>4) <Command>
	====================================================================================================================
	HOUR		| Tests the Current Hour/Minute/Second
	MINUTE	| Example: 	IF (HOUR=14) <Command>
	SECOND	|		IF (MINUTE<=55) <Command>
			|		IF (SECOND=13) <Command>
	====================================================================================================================
	COMPUTERNAME| Tests to see if the command is being executed on a specific Computer
			| This uses the Windows Computer Network Name (as found in Windows System Properties>Computer Name Tab)
			|
			| Example: 	IF (COMPUTERNAME=STUDIO1) <Command>
					(If this is the computer called STUDIO1 then the command is executed)

					IF (COMPUTERNAME<>STUDIO1) <Command>
					(If this is a different computer to STUDIO1 then the command is executed)
	====================================================================================================================
	DATABASE    | Tests to see if the specified database is open
			| Note: This tests the Database Name of the database, not the Description
			|
			| Example: 	IF (DATABASE=MYSTATION) <Command>
					(If the database "MYSTATION" is opened then the command is executed)

					IF (DATABASE<>NOTGOTONE) <Command>
					(If a datavbase is open and it's NOT called NOTGOTONE then execute a command, 
					also if NO database is open, as you don't have NOTGOTONE open)
	====================================================================================================================
	CURRENTUSER | Tests to see if a specific user is logged into Myriad
			| Note: If no-one is logged in then the only test that can be used is "<>" (Different than) 
			| Note: This tests the LoginName of the user, not the FullName
			|
			| Example: 	IF (CURRENTUSER=JOHN) <Command>
					(If John is Logged In then the command is executed)

					IF (CURRENTUSER<>JOHN) <Command>
					(If someone other than John is Logged In then the command is executed)
	====================================================================================================================
	HARDWARE	| Tests the state of a Hardware Line being Set or Clear
			| Example: 	IF (HARDWARE 12=Set) <Command>
					(Checks to see if hardware line 12 is set (or 'Active') i.e. On)

					IF (HARDWARE 101=Clear) <Command>
					(Checks to see if hardware line 101 is Clear (or 'Inactive') i.e. Off)

					IF (HARDWARE 17<>Set) <Command>
					(Checks to see if hardware line 12 is NOT set (or 'Active') i.e. Off)
	====================================================================================================================
	LOGMODE	| Tests the state of the Station Log Mode
			|
			| Possible Answers: AUTOFADE, AUTO or AUTOMATION, LIVE or LIVEASSIST, STANDBY
			|
			| Example: 	IF (LOGMODE=AUTO) <Command>
					(Command will only be executed if in AUTO mode (not AUTOFADE!))
 
					IF (LOGMODE<>STANDBY) <Command>
					(Command will only be executed if not in Standby - i.e. Log is running)
	====================================================================================================================
	LOGGEDIN	| Tests to see if a user is logged into Myriad
			| Example: 	IF (LOGGEDIN=YES) <Command>
					(If a person is Logged In then the command is executed)

					IF (LOGGEDIN=No) <Command>
					(If no one is Logged In then the command is executed)
	====================================================================================================================
	MYRIADCOMPUTERID		| Tests to see if the command is being executed on a specific Computer
					| This uses the Myriad Computer Network ID (as found in Myriad Settings>Computers Tab)
					|
					| Example: 	IF (MYRIADCOMPUTERID=4) <Command>
							(If this is the computer is the 4th in the list then the command is executed)

							IF (MYRIADCOMPUTERNAME<3) <Command>
							(If this is the 1st or 2nd computer in the list then the command is executed)
	====================================================================================================================
	MYRIADCOMPUTERNAME	| Tests to see if the command is being executed on a specific Computer
					| This uses the Myriad Computer Network Name (as found in Myriad Settings>Computers Tab)
					|
					| Example: 	IF (MYRIADCOMPUTERNAME=STUDIO 1) <Command>
							(If this is the computer called STUDIO 1 then the command is executed)

							IF (MYRIADCOMPUTERNAME<>STUDIO 1) <Command>
							(If this is a different computer to STUDIO 1 then the command is executed)
	====================================================================================================================
	ONAIR		| Tests the state of whether the Station Log is "On-Air"
			| Example: 	IF (ONAIR=YES) <Command>
					(If the Log is On-Air then the command is executed)

					IF (ONAIR=No) <Command>
					(If the log is NOT On-Air then the command is executed)

					IF (ONAIR<>YES) <Command>
					(If the log is NOT On-Air then the command is executed)
	====================================================================================================================
	Note: Parameters shown surrounded by square brackets - [] - are optional

	Myriad Command Reference:

	Command	| Usage
	====================================================================================================================
	AUDIOWALL	| Used to change audio stored on the Audiowall
			| Notes: 	These commands do not use Security Permissions.
			|		These commands usually work without any display, so you will not see a warning if a command fails.
			| Commands:
			--------------------------------------------------------------------------------------------------------
			|		COPY 		Used to Copy a specied cart into another specified cart, or the first available in a specified range.
			|		MOVE		Used to Move a specied cart into another specified cart, or the first available in a specified range.
			--------------------------------------------------------------------------------------------------------
			| 		Syntax:	AUDIOWALL COPY <SourceCartNumber>,<StartCartNumber>[,<EndCartNumber>] 					
			| 				AUDIOWALL MOVE <SourceCartNumber>,<StartCartNumber>[,<EndCartNumber>] 					
			|
			|		Notes: 	These commands can only Copy or Move into an empty cart. Use the DELETE command first to ensure that
			|				there is an empty cart available.
			|
			| 		Examples:
			|			AUDIOWALL COPY 1,3001 	   
			|			(Copies cart 1 into cart 3001)
			|
			|			AUDIOWALL MOVE 1,3001,3099
			|			(Moves cart 1 into the first empty cart from 3001 to 3099)
			--------------------------------------------------------------------------------------------------------
			|		DELETE	Used to delete a specified cart
			| 		Syntax:	AUDIOWALL DELETE <CartNumber>
			|
			| 		Examples:
			|			AUDIOWALL DELETE 3001 	   
			|			(Deletes cart 3001)
			--------------------------------------------------------------------------------------------------------
			|		IMPORTFILE 	Used to import a specified Audio File into a specified cart, or the first available in a specified range.
			| 		Syntax:	AUDIOWALL IMPORTFILE <Filename>,<StartCartNumber>[,<EndCartNumber>][,Delete][,NormalisePercentage]
			|		Note:		To use the Normalise Option, you must specify ALL of the parameters. The Normalise Option may be overridden
			|				by the Global Audiowall Settings.
			| 		Examples:
			|			AUDIOWALL IMPORTFILE "c:\Inbox\Myfile1.wav",3001 	   
			|			(Imports the file into cart 3001)
			|
			|			AUDIOWALL IMPORTFILE "c:\Inbox\Myfile2.wav",3001,3099   
			|			(Imports the file into the first available cart from 3001 to 3099)
			|
			|			AUDIOWALL IMPORTFILE "c:\Inbox\Myfile3.wav",3001,Delete,50
			|			(Imports the file into cart 3001 normalised to 50% and then deletes the original file)
			|
			|			AUDIOWALL IMPORTFILE "c:\Inbox\Myfile4.wav",3001,3001,,50
			|			(Imports the file into cart 3001 normalised to 50% but does NOT deletes the file)
			--------------------------------------------------------------------------------------------------------
			|		EXPORT 	Used to export a specified cart to a specified Audio File.
			|		EXPORTFILE 
			|
			| 		Syntax:	AUDIOWALL EXPORT <CartNumber>,<Filename>[,Delete] 	
			|		Note: 	The audio will be exported in it's current format, and the Filename extension will 
			|				be changed to match if nescessary - i.e. exporting an mp3 file to myfile.wav will
			|				actually create a file called myfile.mp3
			| 		Examples:
			|			AUDIOWALL EXPORT 3001,"c:\Inbox\Myfile1.wav"
			|			(Exports cart 3001 to a new file)
			|
			|			AUDIOWALL EXPORT 3001,"c:\Inbox\Myfile2.wav",Delete 
			|			(Exports cart 3001 to a new file then deletes the cart from the audiowall)
			--------------------------------------------------------------------------------------------------------
			|		EXPORTRANGE	Used to export a range of carts to a specified Path using an optional FileTitle format
			|		EXPORTRANGETRANSPORT - Exports as Transport files instead of audio files.
			|
			| 		Syntax:	AUDIOWALL EXPORTRANGE <StartCartNumber>,<EndCartNumber>,<Path>[,FiletitleFormat][,Newer][,<ModifiedInLastHours>]
			|		Note: 	The audio will be exported in it's current format into the specified path using the 
			|				Default Export format or the FileTitleFormat if specified.
			|				Normally it will overwrite any destination files unless you specify the "Newer" flag
			|				in which case it will only overwrite them if the content on the Audiowall is 'Newer'
			|				The <ModifiedInLastHours> option is a number that will only export items modified within the specified 
			|				number of hours of 'now'
			|
			| 		Examples:
			|			AUDIOWALL EXPORTRANGE 3001,3010,"c:\Exports","%CA %TI-%AR",Newer
			|			(Exports any newer carts in the range 3001-3010 to C:\Exports 
			|			with the FileTitle "CartNumber Title-Artist" and a suitable extension i.e. .WAV)
			|
			|			AUDIOWALL EXPORTRANGE 1,9999,"c:\Exports",,,24
			|			(Exports any carts in the range 1-9999 to C:\Exports using the default export format
			|			but only if they have been created/modified in the last 24 hours)
			--------------------------------------------------------------------------------------------------------
			| 		PLAY Player[,Reference][,Sync] - Reference is the Cart number, Sync is used to wait until the cart has finished playing.
			--------------------------------------------------------------------------------------------------------
			|		CUE Player[,Reference]
			--------------------------------------------------------------------------------------------------------
			|		RECUE Player[,Reference]
			--------------------------------------------------------------------------------------------------------
			|		PAUSE Player
			--------------------------------------------------------------------------------------------------------
			|		CLOSE Player
			--------------------------------------------------------------------------------------------------------
			|		EJECT Player
			--------------------------------------------------------------------------------------------------------
			| Example:	AUDIOWALL PLAY 1,3001,Sync
			| 		(This will play cart 3001 in player 1 and wait until it finishes
			--------------------------------------------------------------------------------------------------------
			|		ITEM		  Applies to the specified item or the highlit item if no Cart Numer supplied
			|				  	PREVIEW[,CartNumber]		Previews the cart 
			|				  	PREVIEWHOOK[,CartNumber]	Previews the cart 
			|				  	PREVIEWEXTRO[,CartNumber]	Previews the cart 
			|
			| 		Examples:
			|			AUDIOWALL ITEM PREVIEWHOOK,3001
			| 			(This will play cart 3001 in the preview player.
			|			AUDIOWALL ITEM PREVIEW
			| 			(This will play the highlit cart on the AudioWall in the preview player.

	====================================================================================================================
	COMMAND	| Used to modify or run another Myriad Macro Command
			| Note: 	The Command Processor looks for matching Commands in the following places in order:
			|		  C:\Documents and Settings\All Users\Application Data\P Squared\Myriad v3\Commands
			|		  C:\Documents and Settings\All Users\Application Data\P Squared\Myriad v3\Profiles\<ProfName>\Commands
			|		  <MyriadDataLocation>\Commands
			--------------------------------------------------------------------------------------------------------
			|		RUN <Command>	Loads and runs the specified Command
			| 					Example: 	COMMAND RUN PlayNewsCart
			--------------------------------------------------------------------------------------------------------
			|		DELETE <Command>	Permanently deletes the specified Command
			| 					Example: 	COMMAND DELETE TempCommand
			--------------------------------------------------------------------------------------------------------
			|		RENAME <OldCommandname>,<NewCommandName>	
			|					Renames the Specified Command
			| 					Example: 	COMMAND RENAME MYCOMMAND,MYNEWCOMMAND
			--------------------------------------------------------------------------------------------------------

	====================================================================================================================
	DASHBOARD	| Used to control the Dashboard (Note: only available in Myriad Enterprise)
			| Commands:
			--------------------------------------------------------------------------------------------------------
			|		--------------------------------------------------------------------------------------------
			|		DUMPCURRENT   Changes the ending of the currently playing item to a STOP and then ejects it
			|		--------------------------------------------------------------------------------------------
			|		DUMPNEXT      Soft deletes the next Item
			|		--------------------------------------------------------------------------------------------
			|		DUMPLATER     Soft deletes the 'later'y Item
			--------------------------------------------------------------------------------------------------------

	====================================================================================================================
	DATABASE	| Used to affect the Database of Items stored in the Station Database. Only works if a Station Database is open
			| Commands:
			--------------------------------------------------------------------------------------------------------
			|		FILLFROMAUDIOWALL	Fills the Database using Categorised carts from the AudioWall
			--------------------------------------------------------------------------------------------------------
			|		REBUILDDECKS  	Rebuilds the Decks used by InstantTrack
			--------------------------------------------------------------------------------------------------------

	====================================================================================================================
	DEBUG/	| Used to change the debugging mode used when diagnosing problems. Any of the following syntax options will work.
	DEBUGMODE/	| Commands:
			--------------------------------------------------------------------------------------------------------
			|		OFF/NONE/0		Turn off debugging
			--------------------------------------------------------------------------------------------------------
			|		MEDIUM/5		Medium debugging
			--------------------------------------------------------------------------------------------------------
			|		ON/HIGH/MAX/10	Full debugging
			|
			| Example: 	DEBUG MEDIUM
			|		(Sets Debugging mode to Medium)
			| 		DEBUG 10
			|		(Turns Debugging mode to Full Debugging)
|		DEBUG OFF
			|		(Turns off Debugging mode)
	====================================================================================================================
	EXECUTE/	| Used to run an external (Windows) executable:
	EXTERNAL	| Note: This is similar to the "External" top level command type, but you cannot specify the Priority
			| 	  Syntax:	EXECUTE WAIT|NOWAIT <Filename[ Parms]>
			|
			|	  Example:	EXECUTE NOWAIT notepad.exe c:\myfile.txt
			|			(Loads notepad and displays the file myfile.txt)
			|
			|			EXECUTE WAIT MyProgram.exe MyParameters
			|			(Loads and runs MyProgram.exe and waits until it has completed)
	====================================================================================================================
	HARDWARE	| Used to Set/Clear/Flash/Pulse a hardware line 
			| Example: 	HARDWARE Pulse 12
			| 		(This will cause line 12 to pulse)
	====================================================================================================================
	INSTANTCART | Used to Play or Cue a specified Instant Cart
	IC		| Commands:
			--------------------------------------------------------------------------------------------------------
	            |		LOADSET Reference,SHARED/PRIVATE/NETWORK
			--------------------------------------------------------------------------------------------------------
	            |		PLAY Reference[,Sync]
			--------------------------------------------------------------------------------------------------------
			|		CUE Reference
			--------------------------------------------------------------------------------------------------------
	            | Example:	INSTANTCART PLAY 2,Sync
			| 		(This will play Instant Cart 2 and wait until it finishes
			--------------------------------------------------------------------------------------------------------
			|		VIEW SHOW 		Displays the Docked ICs if not visible - only applies if a user is logged in.
			|		VIEW HIDE 		Hides the Docked ICs if visible - only applies if a user is logged in.
			|		VIEW TOGGLE		Shows or Hides the ICs as appropriate - only applies if a user is logged in.
			--------------------------------------------------------------------------------------------------------
	====================================================================================================================
	LOG/		| Used to change the Log mode or move around in the log
	QNXT		| Commands:
			--------------------------------------------------------------------------------------------------------
			|		GO 		  Move on to the next item in the Log
			--------------------------------------------------------------------------------------------------------
			|		OPENDATABASE  Opens the specified Station Log. This command is ignored if QAE is running.
			|				  Example:	LOG OPENDATABASE OBITLOG
			|						(Opens a Station Database called OBITLOG)
			--------------------------------------------------------------------------------------------------------
			|		CLOSEDATABASE Closes the current Station Log. This command is ignored if QAE is running.
			|				  Example:	LOG CLOSEDATABASE 
			|						(Closes any open Station Database)
			--------------------------------------------------------------------------------------------------------
			|		PRECUE	  Precues the next log item ready to play
			|		--------------------------------------------------------------------------------------------
			|		TOGGLEENDING  Changes the ending of the currently playing item
			|		--------------------------------------------------------------------------------------------
			|		DUMPCURRENT   Changes the ending of the currently playing item to a STOP and then ejects it
			|		--------------------------------------------------------------------------------------------
			|		DUMPNEXT      Soft deletes the next Item
			--------------------------------------------------------------------------------------------------------
			|		ITEM		  Applies to the specified item or the highlit item if no Reference supplied
			|				  	PREVIEW[,Reference]		Previews the item 
			|				  	--------------------------------------------------------------------------
			|				  	CUEHOOK[,Reference]		Cues the Hook of the item 
			|				  	PLAYHOOK[,Reference]		Plays the Hook of the item 
			|				  	PREVIEWHOOK[,Reference]		Previews the Hook of the item 
			|				  	--------------------------------------------------------------------------
			|				  	CUT[,Reference]			'Cuts' the item
			|				  	--------------------------------------------------------------------------
			|				  	COPY[,Reference]			'Copies' the item
			|				  	--------------------------------------------------------------------------
			|				  	PASTE[,Reference]			'Pastes' the Cut or Copied item
			|				  	--------------------------------------------------------------------------
			|				  	SWAP[,Reference]			'Swaps' the Cut item with the highlit item
			|				  	--------------------------------------------------------------------------
			|				  	DELETE[,Reference]		Permanently Deletes the item
			|				  	--------------------------------------------------------------------------
			|				  	TOGGLEDELETE[,Reference]	Deletes/Restores the item
			|				  	--------------------------------------------------------------------------
			|				  	TOGGLEENDING[,Reference]	Toggles the ending of the item
			--------------------------------------------------------------------------------------------------------
			|		VIEW		  Changes the Log View
			|				  ------------------------------------------------------------------------------
			|				  HOME 		Jump to 'now'
			|				  ------------------------------------------------------------------------------
			|				  NEXTHOUR		Scroll up to nearest hour start
			|				  ------------------------------------------------------------------------------
			|				  PREVHOUR		Scroll down to next hour start
			|				  ------------------------------------------------------------------------------
			|				  PAGEUP		Scroll up one page
			|				  ------------------------------------------------------------------------------
			|				  PAGEDOWN		Scroll down one page
			|				  ------------------------------------------------------------------------------
			|				  SCROLLUP		Scroll up one line
			|				  ------------------------------------------------------------------------------
			|				  SCROLLDOWN	Scroll down one line
			|				  ------------------------------------------------------------------------------
			|				  TOP			Scroll to the Top of the log.
			|				  ------------------------------------------------------------------------------
			|				  JUMP,Reference	Jumps to the specified item in the log 
			|				  ------------------------------------------------------------------------------
			|				  JUMPDATETIME,XMLDateTime	Jumps to the first item after the specified time
			|									in the log 
			|									Version: This command was introduced in Myriad v4.0.19
			|				  ------------------------------------------------------------------------------
			|				  JUMPDATETIMEHOUR,XMLDateTime	Jumps to the hour start for the specified 
			|										time in the log.
			|										Version: This command was introduced in Myriad v4.0.19
			--------------------------------------------------------------------------------------------------------
			|		MODE		  Change QAE's running mode
			|				  ------------------------------------------------------------------------------
			|				  HOURMODE		Change to the original play mode for the current hour
			|				  ------------------------------------------------------------------------------
			|				  AUTOFADE		Change to AutoFade mode
			|				  ------------------------------------------------------------------------------
			|				  AUTO/AUTOMATION	Change to Auto Mode
			|				  ------------------------------------------------------------------------------
			|				  LIVE/LIVEASSIST	Change to LiveAssist Mode
			|				  ------------------------------------------------------------------------------
			|				  STANDBY		Stop the Log Running
			|				  ------------------------------------------------------------------------------
			|				  TOGGLE		Toggles the mode between Standby and the Hour's original mode
			|				  ------------------------------------------------------------------------------
			|
			|		Example:	  LOG MODE LIVE
			|				  (Changes the Station Log into "Live" mode)
			--------------------------------------------------------------------------------------------------------
			|		REMOVE	  Remove entries from the Scheduled Log
			|				  Note: You should be carefull not to remove the currently running hour.
			|				  ------------------------------------------------------------------------------
			|				  ALL			Remove all entries from the Log
			|
			|							Example:	LOG REMOVE ALL
			|				  					(Removes all entries from the Log)
			|				  ------------------------------------------------------------------------------
			|				  RANGE,StartDateTime,EndDateTime
			|							Remove entire hours from the long from a start to an end date/time
			|							This uses the standard P Squared Date and Time format.
			|
			|							Example:	LOG REMOVE RANGE,nowdayT00:00:00,nowdayTnowhour
			|				  					(Removes all entries from the log from midnight
			|									 today upto and including the current hour.)
			|				  ------------------------------------------------------------------------------
	====================================================================================================================
	ONAIR		| Used to Take/Release 'On-air Control'
			| Commands:
			|		TAKE/REQUEST	Request/Take On-Air control
			--------------------------------------------------------------------------------------------------------
			|		RELEASE		Release On-Air control
			--------------------------------------------------------------------------------------------------------
			|		MESSAGE		Advanced: Sends a formatted network message to the On-Air device being Controlled
|		Example:	  	ONAIR Take
							  	(Takes ‘on air’ control)
	====================================================================================================================
	PAD		| Used to control the Pad
			| Commands:
			--------------------------------------------------------------------------------------------------------
			|		RUN [PLAY][,LOOP]	"Runs" (Loads) the pad, and if PLAY is specified starts the audio playing out.
			--------------------------------------------------------------------------------------------------------
			|		STOP [CLOSE]	"Stops" the pad running, and if CLOSE is specified ejects any playing audio 
			--------------------------------------------------------------------------------------------------------
			|		VIEW SHOW 		Displays the Pad if it's not currently visible - only applies if a user is logged in.
			|		VIEW HIDE 		Hides the Pad if it's currently visible - only applies if a user is logged in.
			|		VIEW TOGGLE		Shows or Hides the Pad as appropriate - only applies if a user is logged in.
			--------------------------------------------------------------------------------------------------------
			|		NEW			Clears the pad list. This command is ignored if the Pad is running at the time.
			--------------------------------------------------------------------------------------------------------
			|		LOAD <Filename>[,CURRENT|NEXT|<HH:MM>]
			|					"Loads" a pre-saved Pad list into the pad.
			|					The FileName can be an absolute or a relative path - if no drive letter or network
			|					share information is included then it is a path relative to the Myriad Data Location.
			|					If the log file is an Advert Log or Music Log, then the optional extra fields are used.
			|
			|					For Advert Log Files:
			|						CURRENT only loads the current Advert Break (based on the exact current time, so
			|						this command can only be used during the exact minute of the advert break.
			|						NEXT loads the next Advert Break listed in the log after the current time.
			|						HH:MM will load a specific Advert Break (such as 02:30)
			|
			|					For Music Log Files:
			|						CURRENT loads the entire "current" hour (based on the exact current time.
			|						NEXT loads the entire of the next hour from the log.
			|						HH:MM will load a specific Hour (such as 02:00) 
			|
			|					Example:  PAD LOAD "c:\logs\my070809.log"
			|						    (Loads the specified file into the pad)
			|
			|						    PAD LOAD "Logs\my<PEP_DATE_YYMMDD>.log",CURRENT
			|						    (Loads the current hour from today’s Music Log file)
			--------------------------------------------------------------------------------------------------------
			|		SAVE <Filename>	"Saves" the Pad to a file.
			--------------------------------------------------------------------------------------------------------
			|		ADD <Reference>	Adds the specfied Cart to the end of the Pad List
			--------------------------------------------------------------------------------------------------------
			|		ADDRANGE <StartRef>,<EndRef>[,MaxNumberToAdd]
			|					Adds up to [MaxNumberToAdd] carts to the pad from the specified range 
			|					Example: PAD ADDRANGE 3001,3099,10 
			|						   (This adds no more than 10 carts from the range 3001 to 3099)
			--------------------------------------------------------------------------------------------------------
			|		SHUFFLE		Shuffles the Pad List. No effect if the Pad is running at the time.
			--------------------------------------------------------------------------------------------------------
			|		EXPORTTOCART <CartNumber>[,Title]
			|					Version: This command was introduced in Myriad v4.0.25
			|					Mixes the Pad List down and imports into the specified cart. 
			|					If you specify a Title this is set as the the Title of the cart.
			--------------------------------------------------------------------------------------------------------
			|		EXPORTTOFILE <Filename>
			|					Version: This command was introduced in Myriad v4.0.25
			|					Mixes the Pad List down to the specified filename. The filename extension
			|					is automatically changed to match the Default Audio Format.
	====================================================================================================================
	PLAYER	| Used to Play, Pause, Cue/Recue, Close/Eject a cart in a player
	     		| Commands:
			--------------------------------------------------------------------------------------------------------
			| 		PLAY Player[,Reference][,Sync] - Reference is the Cart Number, Sync is used to wait until the cart has finished playing.
			--------------------------------------------------------------------------------------------------------
			|		CUE Player[,Reference]
			--------------------------------------------------------------------------------------------------------
			|		RECUE Player[,Reference]
			--------------------------------------------------------------------------------------------------------
			|		PAUSE Player
			--------------------------------------------------------------------------------------------------------
			|		SEEK Player,SecondsIntoCart
			--------------------------------------------------------------------------------------------------------
			|		SEEKPERC Player,PercentageThroughCart
			--------------------------------------------------------------------------------------------------------
			| 		TOGGLEPLAYPAUSE Player - Toggles a player between playing and paused
			--------------------------------------------------------------------------------------------------------
			|		CLOSE Player
			--------------------------------------------------------------------------------------------------------
			|		EJECT Player
			--------------------------------------------------------------------------------------------------------
			| Example:	PLAYER PLAY 1,3001,Sync
			| 		(This will play cart 3001 in player 1 and wait until it finishes
			--------------------------------------------------------------------------------------------------------
			|		SETVOLUME Player,Percentage
			--------------------------------------------------------------------------------------------------------
			|		SETLOGREFERENCE Player,LogReferenceString
			--------------------------------------------------------------------------------------------------------
			|		Command changed in v4.0.19:
			|		FADE [Player],[Reference],NumberSeconds
			|		(You must specify either the Player OR the Reference OR both. You cannot leave both as 0
			--------------------------------------------------------------------------------------------------------
			|		DUCK Player,DuckAmount%[,FadeDuration]
			|		UNDUCK Player,UnDuckAmount%[,FadeDuration]
			|					Version: These commands were introduced in Myriad v4.0.16
			--------------------------------------------------------------------------------------------------------
			|		PREVIEWMODE Player,REQUEST|FORCE|CLEAR	
			|					Controls if a player is in Preview mode. 
			|					
			|					REQUEST will only set Preview mode if it is empty or when it becomes empty
			|					FORCE forces the player into Preview mode immediately
			|					CLEAR clears Preview mode immediately.
			--------------------------------------------------------------------------------------------------------
			|		TAGPLAYINGAUDIO Player	
			|					Notes information about currently playing audio into the Tagged folder
			|					If you specify ALL for the Player then all items are tagged.
			--------------------------------------------------------------------------------------------------------
	====================================================================================================================
	RECORDER	| Used to Record a new cart in a player
	     		| Commands:
			--------------------------------------------------------------------------------------------------------
			| 		RECORD [Reference][,LevelTrigger] - if no Reference then uses first available in current user's range.
			--------------------------------------------------------------------------------------------------------
			|		PAUSE
			--------------------------------------------------------------------------------------------------------
			|		RESUME
			--------------------------------------------------------------------------------------------------------
			|		CLOSE Save
			--------------------------------------------------------------------------------------------------------
			|		CLOSE Discard
			--------------------------------------------------------------------------------------------------------
			|		CLOSE Prompt
			--------------------------------------------------------------------------------------------------------
			| Example:	RECORDER RECORD 3001
			| 		(This will start recording into cart 3001
	====================================================================================================================
	SEGEDIT	| Used to maniuplate the Segue Editor
	     		| Commands:
			--------------------------------------------------------------------------------------------------------
			| 		OPENDISPLAY
			--------------------------------------------------------------------------------------------------------
			| 		CLOSEDISPLAY
			--------------------------------------------------------------------------------------------------------
			| 		TOGGLEDISPLAY
			--------------------------------------------------------------------------------------------------------
			| 		STEP
	====================================================================================================================
	SOCIAL	| Used to send a Social Media Message on to a Myriad OCP to be sent to Twitter of Facebook.
			| The format is "SOCIAL <Reference> <Your Message>" - Reference can be "TWIT", "FACE" or "TWITFACE"
			--------------------------------------------------------------------------------------------------------
			| Examples:	
			|		SOCIAL TWIT You've just gotta love twitter
			|		SOCIAL FACEBOOK Facebook is the place to be
			|		SOCIAL TWITFACE Can't decide between Twitter or Facebook? Send to both!
	====================================================================================================================
	SPLIT		| Used to send a split command to a Myriad Network system
			|
			| There are no specific commands pre-defined, all text after the "SPLIT" prefix is forwarded straight
			| onto the Myriad Network On-Air Controllers
	====================================================================================================================
	REM/		| Any text on this line will be ignored by the Macro Command Processor.
	REMARK/	| It is therefore ideal for leaving remarks to indicate what the command is doing
			| Example:
			|		REM Don't forget that if you alter this command you have to also update the other one
			|		REMARK Last Updated in June

	====================================================================================================================
	USER		| Used to control the currently logged in user. These commands are extremely dangerous and can result
			| in Myriad closing down if not used carefully. Please contact P Squared Support for more information.
	====================================================================================================================
	WAIT		| Waits for a number of seconds
			| Example:	WAIT 5.5
			|		(this will wait for 5.5 seconds)
	====================================================================================================================
	WEB/		| Opens the Quick web browser and displays a specified file or webpage
	WEBBROWSER/	| Parameters: URL,Caption
	WEBVIEW	| Commands:
			|		VIEW			Display the given URL must include the http:// prefix
			| Example:	WEB VIEW http://www.psquared.net,P Squared's Website
	====================================================================================================================
Serial:
	Used to send a string out of a serial port attached to the local computer.

	Example:	Settings: 9600,n,8,1 No handshaking, Com Port 8
			String: ABCD1234567890

TCPIP:
	Used to connect to a remote computer via a TCP/IP port and send a string of information

	Example:	Settings: Connect via TCP to 192.168.0.1
			String: ABCD1234567890